<?php

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/

use App\Http\Middleware\Authenticate;
use Illuminate\Support\Facades\Route;

Route::get('/', 'AppController@index')->name('home'); //主页
Route::get('login', 'Auth\LoginController@showLoginForm')->name('login');
Route::get('logout', 'Auth\LoginController@logout')->name('apps.logout'); //退出登录
Route::get('uaclogout', 'Auth\LoginController@uaclogout')->name('apps.uaclogout'); //退出登录
Route::view('relogin', 'apps.relogin')->name('relogin');
Route::view('apps/index', 'apps.index')->name('apps.index');
Route::match(['get','post'], 'rpc', 'WebServiceController@index')->name('rpc');
Route::post('api', 'OpenApiController@index')->name('api');
Route::post('dec', 'DecController@index')->name('dec');
Route::post('upload/uploadfiles','Upload\UploadController@upload')->name('uploads.upload'); //文件上传
Route::get('download/files','Upload\UploadController@FileDownload')->name('download.FileDownload'); //文件下载
Route::get('download/filesDel','Upload\UploadController@FileDownloadDel')->name('download.FileDownloadDel'); //文件下载并且删除
Route::get('excelDownload', 'Download\TemplateController@excelDownload')->name('template.excelDownload');//Excel模板文件下载
Route::view('apps/disable', 'apps.disable')->name('apps.disable');

//二维码
Route::view('teaching/qrcode/index', 'qrcode.index')->name('qrcode.index');
Route::post('addActivitySign', 'Teaching\ActivityController@addActivitySign'); //签到
Route::middleware('auth')->prefix('home')->group(function() {
    Route::get('index', 'HomeController@index')->name('home.index'); //主页
});

//基本信息
Route::middleware('auth')->prefix('information')->group(function(){
    //教师档案袋
    Route::prefix('archives')->middleware('checkpower:14')->group(function(){
        Route::get('/', 'Information\ArchivesController@index')->name('archives.home');
        Route::view('index', 'information.archives.index')->name('archives.index');
        Route::view('info', 'information.archives.info')->name('archives.info');
        Route::view('check', 'information.archives.check')->name('archives.check');
        Route::post('addPosition', 'Information\ArchivesController@addPosition')->name('archives.addPosition'); //添加数据
        Route::post('addLearnHistory', 'Information\ArchivesController@addLearnHistory')->name('archives.addLearnHistory'); //添加数据
        Route::post('addWorkHistory', 'Information\ArchivesController@addWorkHistory')->name('archives.addWorkHistory'); //添加数据
        Route::post('addAssessment', 'Information\ArchivesController@addAssessment')->name('archives.addAssessment'); //添加数据
        Route::post('editPosition', 'Information\ArchivesController@editPosition')->name('archives.editPosition'); //编辑数据
        Route::post('editLearnHistory', 'Information\ArchivesController@editLearnHistory')->name('archives.editLearnHistory'); //编辑数据
        Route::post('editWorkHistory', 'Information\ArchivesController@editWorkHistory')->name('archives.editWorkHistory'); //编辑数据
        Route::post('editAssessment', 'Information\ArchivesController@editAssessment')->name('archives.editAssessment'); //编辑数据
        Route::post('delPosition', 'Information\ArchivesController@delPosition')->name('archives.delPosition'); //删除数据
        Route::post('delLearnHistory', 'Information\ArchivesController@delLearnHistory')->name('archives.delLearnHistory'); //删除数据
        Route::post('delWorkHistory', 'Information\ArchivesController@delWorkHistory')->name('archives.delWorkHistory'); //删除数据
        Route::post('delAssessment', 'Information\ArchivesController@delAssessment')->name('archives.delAssessment'); //删除数据

        Route::post('getCheckInfo', 'Information\ArchivesController@getCheckInfo')->name('archives.getCheckInfo');
        Route::post('subBasicInfo', 'Information\ArchivesController@subBasicInfo')->name('archives.subBasicInfo');
        Route::post('subCheckBasicInfo', 'Information\ArchivesController@subCheckBasicInfo')->name('archives.subCheckBasicInfo');
    });
    //下载
    Route::prefix('downld')->middleware('checkpower:15')->group(function(){
        Route::view('/', 'information.downld.index')->name('downla.index');
        Route::post('downloadTeacherInfo', 'Information\DownldController@downloadTeacherInfo')->name('downla.downloadTeacherInfo'); //教师个人作业文件下载
    });
});
//教学研究
Route::middleware('auth')->prefix('teaching')->group(function(){
    // 任教学科
    Route::prefix('discipline')->middleware('checkpower:16|14')->group(function(){
        Route::view('/', 'teaching.discipline.index')->name('discipline.index');
        Route::view('add', 'teaching.discipline.add')->name('discipline.addView');
        Route::view('edit', 'teaching.discipline.edit')->name('discipline.editView');
        Route::view('check', 'teaching.discipline.check')->name('discipline.checkView');
        Route::view('info', 'teaching.discipline.info')->name('discipline.infoView');
        Route::post('getList', 'Teaching\DisciplineController@getList')->name('discipline.list'); //列表数据
        Route::post('add', 'Teaching\DisciplineController@add')->name('discipline.add'); //添加数据
        Route::post('import', 'Teaching\DisciplineController@import')->name('discipline.import'); //导入数据
        Route::post('one', 'Teaching\DisciplineController@one')->name('discipline.one'); //单条数据
        Route::post('edit', 'Teaching\DisciplineController@edit')->name('discipline.edit'); //编辑数据
        Route::post('check', 'Teaching\DisciplineController@check')->name('discipline.check'); //审核
        Route::post('del', 'Teaching\DisciplineController@del')->name('discipline.del'); //删除数据
        Route::post('export', 'Teaching\DisciplineController@export')->name('discipline.export'); //导出数据
    });
    // 公开教学
    Route::prefix('open')->middleware('checkpower:17|14')->group(function(){
        Route::view('/', 'teaching.open.index')->name('open.index');
        Route::view('add', 'teaching.open.add')->name('open.addView');
        Route::view('edit', 'teaching.open.edit')->name('open.editView');
        Route::view('check', 'teaching.open.check')->name('open.checkView');
        Route::view('info', 'teaching.open.info')->name('open.infoView');
        Route::post('export', 'Teaching\OpenController@export')->name('open.export'); //导出数据
        Route::post('exportOpenZip', 'Teaching\OpenController@exportOpenZip')->name('open.exportOpenZip'); //导出数据
    });
    // 经验交流
    Route::prefix('experience')->middleware('checkpower:18|14')->group(function(){
        Route::view('/', 'teaching.experience.index')->name('experience.index');
        Route::view('add', 'teaching.experience.add')->name('experience.addView');
        Route::view('edit', 'teaching.experience.edit')->name('experience.editView');
        Route::view('check', 'teaching.experience.check')->name('experience.checkView');
        Route::view('info', 'teaching.experience.info')->name('experience.infoView');
        Route::post('export', 'Teaching\ExperienceController@export')->name('experience.export'); //导出数据
    });
    // 项目化
    Route::prefix('project')->middleware('checkpower:359|14')->group(function(){
        Route::view('/', 'teaching.project.index')->name('project.index');
        Route::view('add', 'teaching.project.add')->name('project.addView');
        Route::view('edit', 'teaching.project.edit')->name('project.editView');
        Route::view('check', 'teaching.project.check')->name('project.checkView');
        Route::view('info', 'teaching.project.info')->name('project.infoView');
        //Route::post('export', 'Teaching\ProjectController@export')->name('project.export'); //导出数据
    });
    //导师制
    Route::prefix('teacher')->middleware('checkpower:360|14')->group(function(){
        Route::view('/', 'teaching.teacher.index')->name('teaching.teacher.index');
        Route::view('add', 'teaching.teacher.add')->name('teaching.teacher.addView');
        Route::view('edit', 'teaching.teacher.edit')->name('teaching.teacher.editView');
        Route::view('check', 'teaching.teacher.check')->name('teaching.teacher.checkView');
        Route::view('info', 'teaching.teacher.info')->name('teaching.teacher.infoView');
        //Route::post('export', 'Teaching\ProjectController@export')->name('project.export'); //导出数据
    });
    // 课题研究
    Route::prefix('study')->middleware('checkpower:19|14')->group(function(){
        Route::view('/', 'teaching.study.index')->name('study.index');
        Route::view('add', 'teaching.study.add')->name('study.addView');
        Route::view('edit', 'teaching.study.edit')->name('study.editView');
        Route::view('stage', 'teaching.study.stage')->name('study.stageView');
        Route::view('check', 'teaching.study.check')->name('study.checkView');
        Route::view('info', 'teaching.study.info')->name('study.infoView');
        Route::post('getStudyList', 'System\ActivityController@getStudyList')->name('study.getStudyList'); //申报上传数据
        Route::post('uploadStage', 'System\ActivityController@uploadStage')->name('study.uploadStage'); //申报上传数据
        Route::post('checkStage', 'System\ActivityController@checkStage')->name('study.checkStage'); //申报审核数据
        Route::post('generateStage', 'System\ActivityController@generateStage')->name('study.generateStage'); //生成相关文件数据
        Route::post('export', 'Teaching\StudyController@export')->name('study.export'); //导出数据
    });
    // 论文发表
    Route::prefix('paper')->middleware('checkpower:20|14')->group(function(){
        Route::view('/', 'teaching.paper.index')->name('paper.index');
        Route::view('add', 'teaching.paper.add')->name('paper.addView');
        Route::view('edit', 'teaching.paper.edit')->name('paper.editView');
        Route::view('check', 'teaching.paper.check')->name('paper.checkView');
        Route::view('info', 'teaching.paper.info')->name('paper.infoView');
        Route::post('export', 'Teaching\PaperController@export')->name('paper.export'); //导出数据
    });
    // 论著发表
    Route::prefix('treatise')->middleware('checkpower:21|14')->group(function(){
        Route::view('/', 'teaching.treatise.index')->name('treatise.index');
        Route::view('add', 'teaching.treatise.add')->name('treatise.addView');
        Route::view('edit', 'teaching.treatise.edit')->name('treatise.editView');
        Route::view('check', 'teaching.treatise.check')->name('treatise.checkView');
        Route::view('info', 'teaching.treatise.info')->name('treatise.infoView');
        Route::post('export', 'Teaching\TreatiseController@export')->name('treatise.export'); //导出数据
    });
    // 开发科目
    Route::prefix('subject')->middleware('checkpower:22|14')->group(function(){
        Route::view('/', 'teaching.subject.index')->name('subject.index');
        Route::view('add', 'teaching.subject.add')->name('subject.addView');
        Route::view('edit', 'teaching.subject.edit')->name('subject.editView');
        Route::view('check', 'teaching.subject.check')->name('subject.checkView');
        Route::view('info', 'teaching.subject.info')->name('subject.infoView');
        Route::post('export', 'Teaching\SubjectController@export')->name('subject.export'); //导出数据
        Route::post('copySubject', 'Teaching\SubjectController@copySubject')->name('subject.copySubject'); //复用数据
    });
    // 教研活动
    Route::prefix('activity')->middleware('checkpower:23|14')->group(function(){
        Route::view('/', 'teaching.activity.index')->name('tactivity.index');
        Route::view('add', 'teaching.activity.add')->name('tactivity.addView');
        Route::view('edit', 'teaching.activity.edit')->name('tactivity.editView');
        Route::view('join', 'teaching.activity.join')->name('tactivity.joinView');
        Route::view('info', 'teaching.activity.info')->name('tactivity.infoView');
        Route::view('read', 'teaching.activity.read')->name('tactivity.readView');
        Route::view('homework', 'teaching.activity.homework')->name('tactivity.homeworkView');
        Route::post('getList', 'Teaching\ActivityController@getList')->name('tactivity.list'); //列表数据
        Route::post('add', 'Teaching\ActivityController@add')->name('tactivity.add');//活动添加
        Route::post('addHomework', 'Teaching\ActivityController@addHomework')->name('tactivity.addHomework');//活动添加作业
        Route::post('one', 'Teaching\ActivityController@one')->name('tactivity.one'); //单条数据
        Route::post('edit', 'Teaching\ActivityController@edit')->name('tactivity.edit');//活动编辑
        Route::post('download', 'Teaching\ActivityController@download')->name('tactivity.download'); //教师个人作业文件下载
        Route::post('delHomework', 'Teaching\ActivityController@delHomework')->name('tactivity.delHomework');//删除作业
        Route::post('getHomeworkInfo', 'Teaching\ActivityController@getHomeworkInfo')->name('tactivity.getHomeworkInfo'); //作业数据
        Route::post('saveHomework', 'Teaching\ActivityController@saveHomework')->name('tactivity.saveHomework'); //作业提交
        Route::post('addComment', 'Teaching\ActivityController@addComment')->name('tactivity.addComment'); //添加评论
        Route::post('getQRCode', 'Teaching\ActivityController@getQRCode')->name('tactivity.getQRCode'); //获取二维码
        Route::post('getJoinList', 'Teaching\ActivityController@getJoinList')->name('tactivity.getJoinList'); //活动参与进度数据
        Route::post('export', 'Teaching\ActivityController@export')->name('tactivity.export'); //活动参与进度数据导出
        Route::post('downloadHomework', 'Teaching\ActivityController@downloadHomework')->name('tactivity.downloadHomework'); //教师个人作业文件下载
        Route::post('exportTeaActivity', 'Teaching\ActivityController@exportTeaActivity')->name('tactivity.exportTeaActivity'); //列表数据导出
        Route::post('push', 'Teaching\ActivityController@push')->name('tactivity.push'); //作业推优

        Route::post('generateCertificate', 'Teaching\ActivityController@generateCertificate')->name('tactivity.generateCertificate'); //生成证明单
    });
    // 直播管理
    Route::prefix('live')->group(function() {
        Route::view('/', 'teaching.live.index')->name('live.index');
        Route::view('add', 'teaching.live.add')->name('live.addView');
        Route::view('schedule', 'teaching.live.schedule')->name('live.schedule');
        Route::view('edit', 'teaching.live.edit')->name('live.editView');
        Route::view('check', 'teaching.live.check')->name('live.checkView');
        Route::view('info', 'teaching.live.info')->name('live.infoView');
        Route::post('getList', 'Teaching\LiveController@getList')->name('live.list'); //列表数据
        Route::post('add', 'Teaching\LiveController@add')->name('activity.add');//直播添加
        Route::post('one', 'Teaching\LiveController@one')->name('activity.one'); //单条数据
        Route::post('edit', 'Teaching\LiveController@edit')->name('activity.edit');//直播编辑
        Route::post('del', 'Teaching\LiveController@del')->name('activity.del'); //直播删除
    });

    //教学反思
    Route::prefix('reflect')->middleware('checkpower:398|14')->group(function(){
        Route::view('/', 'teaching.reflect.index')->name('reflect.index');
        Route::view('add', 'teaching.reflect.add')->name('reflect.addView');
        Route::view('edit', 'teaching.reflect.edit')->name('reflect.editView');
        Route::view('check', 'teaching.reflect.check')->name('reflect.checkView');
        Route::view('info', 'teaching.reflect.info')->name('reflect.infoView');
        //Route::post('export', 'Teaching\ProjectController@export')->name('project.export'); //导出数据
    });
});
//教育工作
Route::middleware('auth')->prefix('education')->group(function(){
    // 班主任
    Route::prefix('headmaster')->middleware('checkpower:25|14')->group(function(){
        Route::view('/', 'education.headmaster.index')->name('headmaster.index');
        Route::view('add', 'education.headmaster.add')->name('headmaster.addView');
        Route::view('edit', 'education.headmaster.edit')->name('headmaster.editView');
        Route::view('check', 'education.headmaster.check')->name('headmaster.checkView');
        Route::view('info', 'education.headmaster.info')->name('headmaster.infoView');
        Route::post('getList', 'Education\HeadMasterController@getList')->name('headmaster.list'); //列表数据
        Route::post('add', 'Education\HeadMasterController@add')->name('headmaster.add'); //添加数据
        Route::post('one', 'Education\HeadMasterController@one')->name('headmaster.one'); //单条数据
        Route::post('edit', 'Education\HeadMasterController@edit')->name('headmaster.edit'); //编辑数据
        Route::post('del', 'Education\HeadMasterController@del')->name('headmaster.del'); //删除数据
        Route::post('export', 'Education\HeadMasterController@export')->name('headmaster.export'); //导出数据
        Route::post('check', 'Education\HeadMasterController@check')->name('headmaster.check'); //审核
    });
    // 社会实践
    Route::prefix('practice')->group(function(){
        Route::view('/', 'education.practice.index')->name('practice.index');
        Route::view('add', 'education.practice.add')->name('practice.addView');
        Route::view('edit', 'education.practice.edit')->name('practice.editView');
        Route::view('check', 'education.practice.check')->name('practice.checkView');
        Route::view('info', 'education.practice.info')->name('practice.infoView');
        Route::post('export', 'Education\PracticeController@export')->name('practice.export'); //导出数据
    });
    // 班队会
    Route::prefix('meeting')->group(function(){
        Route::view('/', 'education.meeting.index')->name('meeting.index');
        Route::view('add', 'education.meeting.add')->name('meeting.addView');
        Route::view('edit', 'education.meeting.edit')->name('meeting.editView');
        Route::view('check', 'education.meeting.check')->name('meeting.checkView');
        Route::view('info', 'education.meeting.info')->name('meeting.infoView');
    });
    // 主题活动
    Route::prefix('theme')->middleware('checkpower:28|14')->group(function(){
        Route::view('/', 'education.theme.index')->name('theme.index');
        Route::view('add', 'education.theme.add')->name('theme.addView');
        Route::view('edit', 'education.theme.edit')->name('theme.editView');
        Route::view('check', 'education.theme.check')->name('theme.checkView');
        Route::view('info', 'education.theme.info')->name('theme.infoView');
        Route::post('export', 'Education\ThemeController@export')->name('theme.export'); //导出数据
    });
    // 计划和总结
    Route::prefix('plan')->middleware('checkpower:26|14')->group(function(){
        Route::view('/', 'education.plan.index')->name('plan.index');
        Route::view('add', 'education.plan.add')->name('plan.addView');
        Route::view('edit', 'education.plan.add')->name('plan.editView');
        Route::view('info', 'education.plan.info')->name('plan.infoView');
        Route::view('check', 'education.plan.check')->name('plan.checkView');
        Route::post('export', 'Education\PlanController@export')->name('plan.export'); //导出数据
    });
});
//教师培训
Route::middleware('auth')->prefix('faculty')->group(function(){
    // 开发课程
    Route::prefix('courses')->group(function(){
        Route::view('/', 'faculty.courses.index')->name('courses.index');
        Route::view('add', 'faculty.courses.add')->name('courses.addView');
        Route::view('edit', 'faculty.courses.edit')->name('courses.editView');
        Route::view('check', 'faculty.courses.check')->name('courses.checkView');
        Route::view('info', 'faculty.courses.info')->name('courses.infoView');
        Route::post('export', 'Faculty\CourseController@export')->name('courses.export'); //导出数据
    });
    // 学分培训
    Route::prefix('credits')->group(function(){
        Route::view('/', 'faculty.credits.index')->name('credits.index');
        Route::view('info', 'faculty.credits.info')->name('credits.infoView');
        Route::post('getList', 'Faculty\CreditController@getList')->name('credits.list'); //列表数据
        Route::post('one', 'Faculty\CreditController@one')->name('credits.one'); //单条数据
        Route::post('export', 'Faculty\CreditController@export')->name('credits.export'); //导出数据
    });
    // 参与教研
    Route::prefix('research')->middleware('checkpower:31|14')->group(function(){
        Route::view('/', 'faculty.research.index')->name('research.index');
        Route::view('area', 'faculty.research.area')->name('research.area');
        Route::view('add', 'faculty.research.add')->name('research.addView');
        Route::view('edit', 'faculty.research.edit')->name('research.editView');
        Route::view('check', 'faculty.research.check')->name('research.checkView');
        Route::view('info', 'faculty.research.info')->name('research.infoView');
        Route::post('export', 'Faculty\ResearchController@export')->name('research.export'); //导出数据
        Route::post('getList', 'Faculty\ResearchController@getList')->name('research.list'); //列表数据
    });
    // 外出培训
    Route::prefix('outraining')->middleware('checkpower:32|14')->group(function(){
        Route::view('/', 'faculty.outraining.index')->name('outraining.index');
        Route::view('add', 'faculty.outraining.add')->name('outraining.addView');
        Route::view('edit', 'faculty.outraining.edit')->name('outraining.editView');
        Route::view('check', 'faculty.outraining.check')->name('outraining.checkView');
        Route::view('info', 'faculty.outraining.info')->name('outraining.infoView');
        Route::post('export', 'Faculty\OutrainingController@export')->name('outraining.export'); //导出数据
    });
    // 其他
    Route::prefix('other')->middleware('checkpower:33|14')->group(function(){
        Route::view('/', 'faculty.other.index')->name('other.index');
        Route::view('add', 'faculty.other.add')->name('other.addView');
        Route::view('edit', 'faculty.other.edit')->name('other.editView');
        Route::view('check', 'faculty.other.check')->name('other.checkView');
        Route::view('info', 'faculty.other.info')->name('other.infoView');
        Route::post('export', 'Faculty\OtherController@export')->name('other.export'); //导出数据
    });
    // 平台学分
    Route::prefix('platform')->middleware('checkpower:50|14')->group(function(){
        Route::view('/', 'faculty.platform.index')->name('platform.index');
        Route::view('info', 'faculty.platform.info')->name('platform.infoView');
        Route::post('getList', 'Faculty\PlatformController@getList')->name('platform.list'); //列表数据
        Route::post('getUserList', 'Faculty\PlatformController@getUserList')->name('platform.userList'); //列表数据
        Route::post('export', 'Faculty\PlatformController@export')->name('platform.export'); //导出数据
    });
});

//获奖情况
Route::middleware('auth')->prefix('awards')->group(function(){
    //获奖情况
    Route::prefix('wards')->group(function(){
        Route::view('/', 'awards.index')->name('awards.wards.index')->middleware('checkpower:11|14');
        Route::view('add', 'awards.add')->name('awards.wards.add')->middleware('checkpower:11');
        Route::view('check', 'awards.check')->name('awards.wards.check')->middleware('checkpower:11');
        Route::view('see', 'awards.see')->name('awards.wards.see')->middleware('checkpower:11|14');
        Route::post('getAwardsList', 'Awards\AwardsController@getAwardsList')->name('awards.wards.getAwardsList');
        Route::post('getParticipantsData', 'Awards\AwardsController@getParticipantsData')->name('awards.wards.getParticipantsData');
        Route::post('addAwards', 'Awards\AwardsController@addAwards')->name('awards.wards.addAwards');
        Route::post('getAwardsFirst', 'Awards\AwardsController@getAwardsFirst')->name('awards.wards.getAwardsFirst');
        Route::post('checkAwards', 'Awards\AwardsController@checkAwards')->name('awards.wards.checkAwards');
        Route::post('delAwards', 'Awards\AwardsController@delAwards')->name('awards.wards.delAwards');
        Route::match(['post', 'get'], 'push', 'Awards\AwardsController@push')->name('awards.wards.push');
        Route::post('exportAwards', 'Awards\AwardsController@exportAwards')->name('awards.wards.exportAwards');
    });
});

//班级荣誉
Route::middleware('auth')->prefix('honor')->group(function(){
    //班级荣誉
    Route::prefix('honor')->middleware('checkpower:358|14')->group(function(){
        Route::view('/', 'honor.index')->name('honor.honor.index');
        Route::view('add', 'honor.add')->name('honor.honor.add');
        Route::view('check', 'honor.check')->name('honor.honor.check');
        Route::view('see', 'honor.see')->name('honor.honor.see');
        Route::post('addHonor', 'Awards\AwardsController@addHonor')->name('honor.honor.addHonor');
        Route::post('exportHonor', 'Awards\AwardsController@exportHonor')->name('honor.honor.exportHonor');
        Route::post('importHonor', 'Awards\AwardsController@importHonor')->name('honor.honor.importHonor');
    });
});
//重要工作
Route::middleware('auth')->prefix('work')->group(function(){
    //带教情况
    Route::prefix('work')->middleware('checkpower:34|14')->group(function(){
        Route::view('/', 'work.work.index')->name('work.work.index');
        Route::view('add', 'work.work.add')->name('work.work.add');
        Route::view('check', 'work.work.check')->name('work.work.check');
        Route::view('see', 'work.work.see')->name('work.work.see');
        Route::post('addWork', 'Work\WorkController@addWork')->name('work.work.addWork');
        Route::post('getWorkList', 'Work\WorkController@getWorkList')->name('work.work.getWorkList');
        Route::post('getDjqkList', 'Work\WorkController@getDjqkList')->name('work.work.getDjqkList');
        Route::post('checkWork', 'Work\WorkController@checkWork')->name('work.work.checkWork');
        Route::post('delWork', 'Work\WorkController@delWork')->name('work.work.delWork');
        Route::post('exportWork', 'Work\WorkController@exportWork')->name('work.work.exportWork');
    });
    //校内工作
    Route::prefix('inwork')->middleware('checkpower:35|14')->group(function(){
        Route::view('/', 'work.inwork.index')->name('work.inwork.index');
        Route::view('add', 'work.inwork.add')->name('work.inwork.add');
        Route::view('check', 'work.inwork.check')->name('work.inwork.check');
        Route::view('see', 'work.inwork.see')->name('work.inwork.see');
        Route::post('addInWork', 'Work\InWorkController@addInWork')->name('work.inwork.addInWork');
        Route::post('getInWorkList', 'Work\InWorkController@getInWorkList')->name('work.inwork.getInWorkList');
        Route::post('checkInWork', 'Work\InWorkController@checkInWork')->name('work.inwork.checkInWork');
        Route::post('delInWork', 'Work\InWorkController@delInWork')->name('work.inwork.delInWork');
        Route::post('exportInWork', 'Work\InWorkController@exportInWork')->name('work.inwork.exportInWork');
    });
    //校外工作
    Route::prefix('outwork')->middleware('checkpower:36|14')->group(function(){
        Route::view('/', 'work.outwork.index')->name('work.outwork.index');
        Route::view('add', 'work.outwork.add')->name('work.outwork.add');
        Route::view('check', 'work.outwork.check')->name('work.outwork.check');
        Route::view('see', 'work.outwork.see')->name('work.outwork.see');
        Route::post('addOutWork', 'Work\OutWorkController@addOutWork')->name('work.outwork.addOutWork');
        Route::post('getOutWorkList', 'Work\OutWorkController@getOutWorkList')->name('work.outwork.getOutWorkList');
        Route::post('checkOutWork', 'Work\OutWorkController@checkOutWork')->name('work.outwork.checkOutWork');
        Route::post('delOutWork', 'Work\OutWorkController@delOutWork')->name('work.outwork.delOutWork');
        Route::post('exportOutWork', 'Work\OutWorkController@exportOutWork')->name('work.outwork.exportOutWork');
    });
});

//考核管理
Route::middleware('auth')->prefix('rating')->group(function(){
    //岗位竞聘
    Route::prefix('job')->group(function(){
        Route::view('/', 'rating.job.index')->name('rating.job.index');
        Route::view('add', 'rating.job.add')->name('rating.job.add');
        Route::view('apply', 'rating.job.apply')->name('rating.job.apply');
        Route::view('hjqk', 'rating.job.hjqk')->name('rating.job.hjqk');
        Route::view('kt', 'rating.job.kt')->name('rating.job.kt');
        Route::view('fbhjl', 'rating.job.fbhjl')->name('rating.job.fbhjl');
        Route::view('jzgz', 'rating.job.jzgz')->name('rating.job.jzgz');
        Route::view('zw', 'rating.job.zw')->name('rating.job.zw');
        Route::view('gkjx', 'rating.job.gkjx')->name('rating.job.gkjx');
        Route::view('jyjl', 'rating.job.jyjl')->name('rating.job.jyjl');
        Route::view('fdxshj', 'rating.job.fdxshj')->name('rating.job.fdxshj');
        Route::view('djqk', 'rating.job.djqk')->name('rating.job.djqk');
        Route::view('qtfzxm', 'rating.job.qtfzxm')->name('rating.job.qtfzxm');
        Route::view('zygzgx', 'rating.job.zygzgx')->name('rating.job.zygzgx');
        Route::view('adminsee', 'rating.job.adminsee')->name('rating.job.adminsee');
        Route::view('check', 'rating.job.check')->name('rating.job.check');
        Route::view('checkSee', 'rating.job.checkSee')->name('rating.job.checkSee');
        Route::view('see', 'rating.job.see')->name('rating.job.see');
        Route::post('addJob', 'Rating\JobController@addJob')->name('rating.job.addJob');
        Route::post('getJobList', 'Rating\JobController@getJobList')->name('rating.job.getJobList');
        Route::post('getJobFirst', 'Rating\JobController@getJobFirst')->name('rating.job.getJobFirst');
        Route::post('delJob', 'Rating\JobController@delJob')->name('rating.job.delJob');
        Route::post('getJobScale', 'Rating\JobController@getJobScale')->name('rating.job.getJobScale');
        Route::post('getJobScaleList', 'Rating\JobController@getJobScaleList')->name('rating.job.getJobScaleList');
        Route::post('getJobApplyFirst', 'Rating\JobController@getJobApplyFirst')->name('rating.job.getJobApplyFirst');
        Route::post('addApply', 'Rating\JobController@addApply')->name('rating.job.addApply');
        Route::post('addFzxxm', 'Rating\JobController@addFzxxm')->name('rating.job.addFzxxm');
        Route::post('delFzxxm', 'Rating\JobController@delFzxxm')->name('rating.job.delFzxxm');
        Route::post('getApplyList', 'Rating\JobController@getApplyList')->name('rating.job.getApplyList');
        Route::post('addJobApplyCheck', 'Rating\JobController@addJobApplyCheck')->name('rating.job.addJobApplyCheck');
        Route::post('getJobApplyCheckFirst', 'Rating\JobController@getJobApplyCheckFirst')->name('rating.job.getJobApplyCheckFirst');
        Route::post('getJobScaleCheckList', 'Rating\JobController@getJobScaleCheckList')->name('rating.job.getJobScaleCheckList');
        Route::post('getFinalJobApplyList', 'Rating\JobController@getFinalJobApplyList')->name('rating.job.getFinalJobApplyList');
        Route::post('getFinatJobScaleList', 'Rating\JobController@getFinatJobScaleList')->name('rating.job.getFinatJobScaleList');
        Route::post('getJobApplyUserCheck', 'Rating\JobController@getJobApplyUserCheck')->name('rating.job.getJobApplyUserCheck');
        Route::post('getUserCheckScores', 'Rating\JobController@getUserCheckScores')->name('rating.job.getUserCheckScores');
        Route::post('delJobApply', 'Rating\JobController@delJobApply')->name('rating.job.delJobApply');
        Route::post('exportJobApply', 'Rating\JobController@exportJobApply')->name('rating.job.exportJobApply');
        Route::post('getJobCompetitionInfo', 'Rating\JobController@getJobCompetitionInfo')->name('rating.job.getJobCompetitionInfo');
        Route::post('exportJob', 'Rating\JobController@exportJob')->name('rating.job.exportJob');
    });
    //学年考核
    Route::prefix('check')->group(function(){
        Route::view('/', 'rating.check.index')->name('rating.check.index');
        Route::view('add', 'rating.check.add')->name('rating.check.add');
        Route::view('check', 'rating.check.check')->name('rating.check.check');
        Route::view('checkSee', 'rating.check.checkSee')->name('rating.check.checkSee');
        Route::view('jyjl', 'rating.check.jyjl')->name('rating.check.jyjl');
        Route::view('ktyj', 'rating.check.ktyj')->name('rating.check.ktyj');
        Route::view('lwfb', 'rating.check.lwfb')->name('rating.check.lwfb');
        Route::view('lzfb', 'rating.check.lzfb')->name('rating.check.lzfb');
        Route::view('djqk', 'rating.check.djqk')->name('rating.check.djqk');
        Route::view('zzSee', 'rating.check.zzSee')->name('rating.check.zzSee');
        Route::view('ccSee', 'rating.check.ccSee')->name('rating.check.ccSee');
        Route::post('addCheck', 'Rating\CheckController@addCheck');
        Route::post('getCheckScale', 'Rating\CheckController@getCheckScale');
        Route::post('getCheckList', 'Rating\CheckController@getCheckList');
        Route::post('copyCheck', 'Rating\CheckController@copyCheck');
        Route::post('checkMemberDel', 'Rating\CheckController@checkMemberDel');
        Route::post('getcheckMember', 'Rating\CheckController@getcheckMember');
        Route::post('addCheckMember', 'Rating\CheckController@addCheckMember');
        Route::post('getCheckFirst', 'Rating\CheckController@getCheckFirst');
        Route::post('getCheckTeachersList', 'Rating\CheckController@getCheckTeachersList');
        Route::post('getTeacherBaseInfo', 'Rating\CheckController@getTeacherBaseInfo');
        Route::post('getCheckScaleInfo', 'Rating\CheckController@getCheckScaleInfo');
        Route::post('checkScores', 'Rating\CheckController@checkScores');
        Route::post('getFinalScores', 'Rating\CheckController@getFinalScores');
        Route::post('getCheckScores', 'Rating\CheckController@getCheckScores');
        Route::post('setCheckSort', 'Rating\CheckController@setCheckSort');
        Route::post('delCheck', 'Rating\CheckController@delCheck');
        Route::post('checkTeacherExport', 'Rating\CheckController@checkTeacherExport');
        Route::post('checkExport', 'Rating\CheckController@checkExport');
        Route::post('finalExport', 'Rating\CheckController@finalExport');
    });
});

//系统设置
Route::middleware('auth')->name('systems.')->prefix('systems')->group(function(){
    // 活动
    Route::prefix('activity')->group(function(){
        Route::post('getList', 'System\ActivityController@getList')->name('activity.list'); //列表数据
        Route::post('add', 'System\ActivityController@add')->name('activity.add');//活动添加
        Route::post('one', 'System\ActivityController@one')->name('activity.one'); //单条数据
        Route::post('edit', 'System\ActivityController@edit')->name('activity.edit');//活动编辑
        Route::post('check', 'System\ActivityController@check')->name('activity.check');//活动审核
        Route::post('del', 'System\ActivityController@del')->name('activity.del'); //活动删除
        Route::post('push', 'System\ActivityController@push')->name('activity.push'); //推优
        Route::post('pushOne', 'System\ActivityController@pushOne')->name('activity.pushOne'); //推优单个文件
        Route::post('getJyjlList', 'System\ActivityController@getJyjlList');
        Route::post('getKtyjList', 'System\ActivityController@getKtyjList');
        Route::post('getLwfbList', 'System\ActivityController@getLwfbList');
        Route::post('getLzfbList', 'System\ActivityController@getLzfbList');
    });

    // 教师信息
    Route::prefix('teacher')->group(function(){
        Route::view('manage','systems.teacher.index')->name('teacher.index'); //管理查看页面
        Route::post('getList', 'System\TeacherController@getList')->name('teacher.getList');//获取教师信息列表数据
        Route::post('getBaseInfo', 'System\TeacherController@getBaseInfo')->name('teacher.getBaseInfo'); //获取教师信息数据
        Route::post('getPosition', 'System\TeacherController@getPosition')->name('teacher.getPosition');
        Route::post('updateUserAssessment', 'System\TeacherController@updateUserAssessment')->name('teacher.updateUserAssessment');
        Route::post('updateUsersAssessment', 'System\TeacherController@updateUsersAssessment')->name('teacher.updateUsersAssessment');
        Route::post('export', 'System\TeacherController@export')->name('teacher.export');//导出教师信息列表数据
    });

    // 考核量表
    Route::prefix('scales')->group(function(){
        Route::view('/', 'systems.scales.index')->name('scales.index');
        Route::view('add', 'systems.scales.add')->name('scales.addView');
        Route::view('edit', 'systems.scales.edit')->name('scales.editView');
        Route::view('deal', 'systems.scales.deal')->name('scales.dealView');
        Route::post('list', 'System\ScaleController@list')->name('scales.list');//获取量表列表数据
        Route::post('add', 'System\ScaleController@add')->name('scales.add');//添加数据
        Route::post('copy', 'System\ScaleController@copy')->name('scales.copy');//量表复制
        Route::post('addDetail', 'System\ScaleController@addDetail')->name('scales.addDetail');//量表考核内容新增
        Route::post('addRowDetail', 'System\ScaleController@addRowDetail')->name('scales.addRowDetail');//量表考核行内容新增
        Route::post('getOne', 'System\ScaleController@getOne')->name('scales.getOne'); //获取单条数据
        Route::post('edit', 'System\ScaleController@edit')->name('scales.edit');//编辑量表
        Route::post('del', 'System\ScaleController@del')->name('scales.del');//删除量表
        Route::post('editDetail', 'System\ScaleController@editDetail')->name('scales.editDetail');//量表考核内容编辑
        Route::post('delDetail', 'System\ScaleController@delDetail')->name('scales.delDetail');//量表考核内容删除
        Route::post('updateDetail', 'System\ScaleController@updateDetail')->name('scales.updateDetail');//单个量表考核内容修改
        Route::post('getSelectList', 'System\ScaleController@selectList')->name('scales.selectList');//考核量表下拉选择数据
    });
    Route::middleware('checkpower:4')->group(function() {
        Route::get('logs', 'System\LogController@index')->name('logs.index');
        Route::post('logs/list', 'System\LogController@getList');
    });

    // 角色权限 ---> qiankun ---> 20250612
    Route::middleware('checkpower:3')->group(function() {
        Route::prefix('roles')->group(function () {
            Route::post('getRoleUsers', 'System\RoleController@getRoleUsers')->name('roles.getRoleUsers');//获取角色人员
        });
        Route::get('powers', 'System\RoleController@index')->name('roles.index');
        Route::post('roles/list', 'System\RoleController@getList')->name('roles.list');
        Route::post('roles/add', 'System\RoleController@add')->name('roles.add');
        Route::post('roles/edit', 'System\RoleController@edit')->name('roles.edit');
        Route::post('roles/delete', 'System\RoleController@delete')->name('roles.delete');
        Route::post('roles/powertree', 'System\RoleController@getPowerTree')->name('roles.powertree');
        Route::post('roles/rolepowers', 'System\RoleController@getRolePowers')->name('roles.rolepowers');
        Route::post('roles/setrolepowers', 'System\RoleController@setRolePowers')->name('roles.setrolepowers');
    });
    // 用户设置 ---> qiankun ---> 20250612
    Route::prefix('users')->group(function(){
        Route::get('/', 'System\UserController@index')->name('users.index')->middleware('checkpower:2');
        Route::post('list', 'System\UserController@getList')->name('users.list')->middleware('checkpower:2');
        Route::post('getallrole', 'System\UserController@getAllRole')->name('users.getallrole');
        Route::post('setuserrole', 'System\UserController@setUserRole')->name('users.setuserrole');
        Route::post('setuserstatus', 'System\UserController@setUserStatus')->name('users.setuserstatus');
        Route::post('getgrouptree', 'System\UserController@getGroupTree')->name('users.getgrouptree');
        Route::post('setUserCurRole', 'System\UserController@setUserCurRole')->name('users.setUserCurRole');//设置用户当前角色
        Route::post('updateInfo', 'System\UserController@updateInfo')->name('users.updateInfo');//导入用户信息

    });
    Route::prefix('users')->group(function(){
        //获取菜单
        Route::get('getUserMenus', 'System\UserController@getUserMenus')->name('users.getUserMenus');
    });
    //学期相关
    Route::view('term', 'systems.terms.index')->name('terms.index')->middleware('checkpower:6');
    Route::post('getTermList', 'System\TermController@getTermList');
    Route::post('setTerm', 'System\TermController@setTerm');
    Route::post('getTermById', 'System\TermController@getTermById');
    Route::post('delTerm', 'System\TermController@delTerm')->middleware('checkpower:302');;

    Route::post('getTermData', 'System\TermController@getTermData');
    //班级相关
    Route::post('getClassData', 'System\ClassroomController@getClassData');
    Route::post('getClassMaster', 'System\ClassroomController@getClassMaster');

    //用户机构group
    Route::post('getGroupAllBySchool', 'System\GroupController@getGroupAllBySchool');

    //文件资源
    Route::prefix('files')->group(function() {
        Route::post('/getFilesList', 'System\FilesController@getFilesList');
    });
    //数据字典
    Route::prefix('dics')->group(function(){
        Route::view('/', 'systems.dics.index')->middleware('checkpower:6');
        Route::view('/items', 'systems.dics.items');
        Route::post('/getdiclist', 'System\DicController@getList');
        Route::post('/getdicitemlist', 'System\DicController@getItemList');
        Route::post('/adddicitem', 'System\DicController@addItem');
        Route::post('/adddic', 'System\DicController@add');
        Route::post('/deldicitem', 'System\DicController@deleteItem');
        Route::post('/editdicitem', 'System\DicController@editItem');
        Route::post('/deldic', 'System\DicController@delete');
        Route::post('/editdic', 'System\DicController@edit');
        Route::post('/getdicnamebyname', 'System\DicController@getAllItems');
        Route::post('/getDicListByCode', 'System\DicController@getDicListByCode');//获取字典列表通过code ---------- 公用接口
        Route::post('/getDicListByCodes', 'System\DicController@getDicListByCodes');//获取字典列表通过code(Array)) ---------- 公用接口

        //老字典表接口
        Route::post('/getDictionaryItem', 'System\DictionaryItemController@getDictionaryItem');
        Route::post('/getDictionaryLinkItem', 'System\DictionaryItemController@getDictionaryLinkItem');
        Route::post('/getOriginSelect', 'System\DictionaryItemController@getOriginSelect');
        Route::post('/getDicRelationItem', 'System\DictionaryItemController@getDicRelationItem');
        Route::post('/getDictionaryXmSelect', 'System\DictionaryItemController@getDictionaryXmSelect');//获取老字典多选下拉数据 ---------- 公用接口

    });

    //待办事项
    Route::prefix('task')->group(function(){
        Route::view('/', 'systems.task.index')->middleware('checkpower:203');
        Route::post('getTaskList', 'System\TaskController@getTaskList')->name('systems.task.getTaskList');
    });


    //首页
    Route::view('index', 'systems.index')->name('index');
});

// 用户认证相关路由（禁用注册、重置密码、邮件验证功能）
Auth::routes(['register' => false, 'reset' => false, 'verify' => false]);

if (env('APP_ENV') == 'local') { //本地开发环境下可访问测试控制器
    Route::namespace('Test')->prefix('test')->name('test.')->group(function () {
//        Route::get('rpc/sso', 'XmlrpcController@sso');
//        Route::get('rpc/index', 'XmlrpcController@index');
//        Route::get('rpc/node', 'XmlrpcController@node');
        Route::match(['get','post'], 'rpc/server', 'XmlrpcController@server');
        Route::get('switch/{user_id}', 'UserController@switchUser')->where('user_id', '[a-zA-Z0-9_]+');
    });
}
